/*
 * @Author: yopofeng yopofeng@tencent.com
 * @Date: 2024-01-25 11:25:59
 * @LastEditors: yopofeng yopofeng@tencent.com
 * @LastEditTime: 2024-01-25 11:26:29
 * @FilePath: /minitest-demo/miniprogram-demo/cloudfunctions/quickstartFunctions/index.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
const getOpenId = require('./getOpenId/index')
const createUserInfoCollection = require('./createUserInfoCollection/index')
const checkAccount = require('./checkAccount/index')
const bindAccount = require('./bindAccount/index')
const getOpenDatas = require('./getOpenDatas/index')
const getUserRiskRank = require('./getUserRiskRank/index')
const delay = require('./delay/index')


// 云函数入口函数
exports.main = async (event, context) => {
  switch (event.type) {
    case 'getOpenId':
      return await getOpenId.main(event, context);
    case 'createUserInfoCollection':
      return await createUserInfoCollection.main(event, context);
    case 'checkAccount':
      return await checkAccount.main(event, context);
    case 'bindAccount':
      return await bindAccount.main(event, context);
    case 'getOpenDatas':
      return await getOpenDatas.main(event, context)
    case 'getUserRiskRank':
      return await getUserRiskRank.main(event, context)
    case 'delay':
      return await delay.main(event, context)
  }
};
